me3explorerfandomcom-20200213-history
TLK File Format
TLK files contain all the text seen in game. The main game and each DLC contain their own TLKs, all in multiple versions (localizations) for seven languages: *English (INT) *German (DEU) *Italian (ITA) *French (FRA) *Spanish (ESN) *Polish (POL) *Russian (RUS) File Structure All TLK files have the same basic structure. Below is a screenshot of the simplest TLK file, specifically one extracted from the Online Pass . This tutorial assumes you know how to extract a file from an sfar. If not, please refer to the DLC Editor Tool article. Looking at the above, we can see the following: *'UTF-8 Encoding' :The type of character encoding used for the XML file. UTF-8 is the default encoding scheme for XML files and should not be modified, because UTF-8 supports the character sets for multiple languages. This allows you to use special unicode entities which are present throughout the game's strings, such as & being the ampersand. *'Strings' :TLK files contain . Each string has an ID, position, and data fields that are clearly labeled. These fields must be enclosed with proper tags or the game won't read the string. Absence of a forwardslash indicates "start," presence indicates "end/close." This is similar to BBcode. :Some important things to note about strings: :*String IDs are unique within each section :*String IDs are sequential (in order) but not consecutive (e.g, 3, 7, 10) :*Position integers are unique, sequential, AND consecutive (e.g., 1, 2, 3) *'Male/Female Sections' :Languages other than English tend to have gender differences for certain words, often pronouns and verbs. This is the purpose of the Male/Female TLK sections. :For example, the Spanish TLK has two entries for string 713441. "Jefe" or "jefa" is used, depending on Shepard's gender. String data at line 488256 is masculine and in the Male Section. String data at line 534548 is feminine and in the Female Section. A modder who wants to edit this line will need to edit BOTH entries to ensure the change works properly in game. :The English language lacks gender differences for pronouns, nouns, verbs and the like, which is why all strings in are placed in the Male Section. Any new TLK string should also be added to this section. The Female Section is labeled, but unused. The text annotating the start and end of the Male and Female Sections (pictured above in Notepad++ in green) is "commented out" (indicated by ) and doesn't impact the file. The specified positions can be updated as the TLK is edited, but it is for user reference only. The real labels the game reads for these sections are covered below. *'Special Strings' The bottom four strings in the Online Pass TLK screenshot are a special case. They are consistent across all TLKs and should not be edited. This includes : *134217729 = Folder location of TLK. The main game TLK uses . *134217730 = Localization. Spanish TLK uses "es-es". *134217731 (male) = Male Section label *134217731 (female) = Female Section label :Data for the top TLK string, 724024, is similar to that in 134217729. The difference is it contains the "pretty name" of the DLC. This is what the game will display on screen, if there's a DLC error upon load up, for example. It should also not be edited, but this particular string ID changes with DLC. The EC's "pretty name" is located at string 738369. Category:File Formats